home *** CD-ROM | disk | FTP | other *** search
/ Ian & Stuart's Australian Mac 1 / Ian and Stuart's One (Australia).iso / Australasian Legends / Commercial / Rainbow Hill / MacDOS™ 2.0.0 / batches / dupl.bat < prev    next >
DOS Batch File  |  1994-06-30  |  569b  |  26 lines

  1. @echo off
  2. !  dupl.bat    Batch file to duplicate a folder or a file
  3. !
  4. !  dupl name
  5. !
  6. !  where 'name' is the item to be duplicated. The name can be preceded by
  7. !  a path and a volume ID.
  8. !
  9. !  dupl.bat executes duplfile and dupldir
  10. !
  11. !  Copyright © 1994 by Rainbow Hill Pty Ltd. All rights reserved.
  12. !
  13.  
  14.     ! ensure that the first parameter is there and that the second one is not
  15.     set doserr=13
  16.     if not "%2 " == " " goto ERR_LBL
  17.     if "%1 " == " " goto ERR_LBL
  18.  
  19.     ! do the duplication
  20.     if existdir "%1" dupldir "%1"
  21.     duplfile "%1"
  22.     ! it never returns
  23.  
  24. :ERR_LBL
  25.     show %doserr%
  26.